<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %>
<%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%>
<jsp:directive.page contentType="text/html" pageEncoding="UTF-8" />
<html xmlns:jsp="http://java.sun.com/JSP/Page">

<spring:url value="/${curUser.userFName}/edit" var="update"/>
<spring:url value="/${curUser.userFName}/delete" var="delete"/>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Register user</title>
</head>
<body>

<jsp:include page="header.jsp" />
<div id="centered">
        <br/>
        <div class = "forms">
        	<form:form action="${update}" method="POST"
		modelAttribute="curUser">

	First name: <form:input path="userFName" value="${curUser.userFName}" />
	
		<form:errors path="userFName" cssClass="errorLogin" element="div"/>
		<br>
		
		<br/>
	Last name: <form:input path="userLName" value="${curUser.userLName}" />

	<form:errors path="userLName" cssClass="errorLogin" element="div"/>
		<br>
		
		<br/>
	Password: <form:input path="password" value="${curUser.password}" />

	<form:errors path="password" cssClass="errorLogin" element="div"/>
		<br>
		
		<br/>

		<form:button>Update</form:button>

	</form:form>
        </div>
        
        <br/>
         <a href="${delete}">Delete account</a>
        </div>
</body>
</html>